package org.mindrot.jbcrypt;

public class Main {
    public static void main(String[] args) {
        String password = "124566";
        String gensalt = BCrypt.gensalt();
        System.out.println(gensalt);
        String hashpw = BCrypt.hashpw(password, gensalt);
        System.out.println(hashpw);

        //$2a$10$mS4a75H3sQbIgbOyxXv8p.c2ief3LZFvvsv.1Dz6idn/xuiE8ecQa
        String a = "124566";
        String hashpw2 = "$2a$10$mS4a75H3sQbIgbOyxXv8p.c2ief3LZFvvsv.1Dz6idn/xuiE8ecQa";
        boolean checkpw = BCrypt.checkpw(a, hashpw2);
        System.out.println(checkpw);
    }
}
